package com.ruoyi.system.service;

import com.ruoyi.system.domain.*;

import java.io.InputStream;
import java.util.List;

/**
 * 手机库  服务层
 * 
 * @author admin
 */
public interface PhoneService {
    /**
     * 手机号 列表(分页)
     * @param phone
     * @return
     */
    public List<Phone> selectPhoneList(Phone phone);

    /**
     * 数据
     * @param phone
     * @return
     */
    public List<Phone> selectPhoneData(Phone phone);

    /**
     * 标签（分页）
     * @param phoneLabel
     * @return
     */
    public List<PhoneLabel> selectPhoneLabelList(PhoneLabel phoneLabel);

    public List<PhoneLabel> selectPhoneLabelData(PhoneLabel phoneLabel);


    public void writeExelData(InputStream in,String originalFilename);

    /**
     * 大批量数据导入
     * @param path
     * @param originalFilename
     */
    public void writeExcelLargeData(String path,String originalFilename) throws Exception;

    /**
     * 保存数据
     * @param phone
     * @return
     */
    public int insertPhone(Phone phone);

    /**
     * 批量插入
     * @param phones
     * @return
     */
    public int insertBatchPhone(List<Phone> phones);


    public int insertPhoneLabel(PhoneLabel phoneLabel);
    public int updatePhoneLabel(PhoneLabel phoneLabel);


    public Phone getEntityByPhone(String phone);
    public PhoneLabel getEntityById(Long id);

    // 更新
    public int updatePhone(Phone phone);
    public void updateBatchFlag(String flags,List<Phone> phone);


    public int removePhoneLabel(String ids);

    public int removePhoneByFlag(String flag,Long id);

    public void arrangeDatas();
}


